/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package jmvcclab.Controller;

import javax.swing.event.ChangeEvent;
import javax.swing.event.ChangeListener;
import jmvcclab.Model.MainData;

/**
 *
 * @author home
 */
public class QuerryListener {

    MainData m;
    String oldQuery;

    public QuerryListener(MainData model) {
        this.m = model;
        oldQuery = m.Query;
        while (true) {
            if (!oldQuery.equals(m.Query)) {
                oldQuery = m.Query;
                m.QueryHistory[0] = m.Query;
                System.out.println(m.Query);
            }
        }
    }
}
